﻿Public Class DangTinBUS
    Public Sub Insert(ByVal nha As DangTinDTO)
        Dim nhaDAO As New DangTinDAO
        nhaDAO.Insert(nha)
    End Sub
    Public Sub Delete(ByVal nha As DangTinDTO)
        Dim nhaDAO As New DangTinDAO
        nhaDAO.Delete(nha)
    End Sub
    Public Sub Update(ByVal nha As DangTinDTO)
        Dim nhaDAO As New DangTinDAO
        nhaDAO.Update(nha)
    End Sub
    Public Function GetAll() As DataTable
        Dim dtDAO As New DangTinDAO
        Return dtDAO.GetAll()
    End Function
    Public Function GetIemID(ByVal machunha As String) As DataTable
        Dim dtDAO As New DangTinDAO
        Return dtDAO.GetItemID(machunha)
    End Function
    Public Function GetItemTinhTrang(ByVal trangthaiTin As Integer) As DataTable
        Dim dtDAO As New DangTinDAO
        Return dtDAO.GetItemTinhTrang(trangthaiTin)
    End Function
    'Public Function SeachKhuVuc(ByVal tukhoa As String) As DataTable
    '    Dim dtDAO As New DangTinDAO
    '    Return dtDAO.SeachKhuVuc(tukhoa)
    'End Function
    Public Function SeachTin(ByVal tenloainha As String, ByVal tenkhuvuc As String, ByVal giatu As String, ByVal giaden As String) As DataTable
        Dim dtDAO As New DangTinDAO
        Return dtDAO.SeachTin(tenloainha,tenkhuvuc,giatu,giaden)
    End Function
    Public Function SelectID(ByVal matin As Integer) As DangTinDTO
        Dim dtDAO As New DangTinDAO
        Return dtDAO.SelectID(matin)
    End Function
End Class
